import Login from './views/Login.vue'
import Register from './views/Register.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import Main from './views/Main.vue'
import Table from './views/nav1/Table.vue'
import Form from './views/nav1/Form.vue'
import user from './views/nav1/user.vue'
import Page4 from './views/nav2/Page4.vue'
import Page5 from './views/nav2/Page5.vue'
import Page6 from './views/nav3/Page6.vue'
import echarts from './views/charts/echarts.vue'


//--------------自己导入的组件----------------------------------------------
import Department from "./views/org/Department";
import Dictionary from "./views/org/Dictionary";

import PetShengHe from "./views/pet/PetShengHe";
import EditorDemo from "./views/pet/EditorDemo";
import PetUpDown from "./views/pet/PetUpDown";
import ShopOrder from "./views/pet/ShopOrder";
//------------------------------------------------------------

let routes = [
    {
        path: '/login',
        component: Login,
        name: '',
        hidden: true
    },
    {
        path: '/register',
        component: Register,
        name: '',
        hidden: true
    },
    {
        path: '/404',
        component: NotFound,
        name: '',
        hidden: true
    },
    {
        path: '/',
        component: Home,
        name: 'Charts',
        iconCls: 'fa fa-bar-chart',
        children: [
            { path: '/echarts', component: echarts, name: 'echarts' }
        ]
    },
    //{ path: '/main', component: Main },
    {
        path: '/',
        component: Home,
        name: '组织机构管理',
        iconCls: 'el-icon-message',//图标样式class
        children: [
            { path: '/dept', component: Department, name: '部门管理' },
            { path: '/emp', component: Department, name: '员工管理' },
            { path: '/tion', component: Dictionary, name: '字典管理' },
        ]
    },
    {
        path: '/',
        component: Home,
        name: '宠物寻主',
        iconCls: 'fa fa-id-card-o',
        children: [
            { path: '/petshenghe', component: PetShengHe, name: '寻主审核' },
            { path: '/shoporder', component: ShopOrder, name: '门店订单' },
            { path: '/petupdown', component: PetUpDown, name: '宠物上下架' },
            { path: '/editordemo', component: EditorDemo, name: 'quill编辑器' }
        ]
    },
    {
        path: '*',
        hidden: true,
        redirect: { path: '/404' }
    }
];

export default routes;
